	<!--{hook header_nav_start.htm}-->
	<header class="navbar navbar-expand-lg navbar-dark bg-dark" id="header">
		<div class="site-overlay"></div>
		<div class="container">
			<button class="navbar-toggler navigation-drawer border-0 px-0" type="button">
				<?php if(empty($uid)) { ?>
					<img class="avatar-2" src="view/img/avatar.png">
				<?php } else { ?>
					<img class="avatar-2" src="<?php echo $user['avatar_url'];?>">
				<?php } ?>
			</button>
			<!--{hook header_nav_logo_before.htm}-->

			<a class="navbar-brand text-truncate" href="<?php echo $header['mobile_link'];?>">
				<img src="plugin/sifoucn_theme_limpid/img/logo.png">
				<?php if($header['mobile_title']) { ?>
					<span class="hidden-lg"><?php echo $header['mobile_title'];?></span>
				<?php } ?>
			</a>
			
			<!--{hook header_nav_logo_after.htm}-->
			
			<?php if(empty($uid)) { ?>
				<a class="navbar-brand hidden-lg mx-0" href="<?php echo url('user-login');?>" aria-label="<?php echo lang('login');?>"> <i class="icon-user icon"></i></a>
			<?php } else { ?>
				<a class="navbar-brand hidden-lg mx-0" href="<?php echo url("thread-create-$fid");?>" aria-label="<?php echo lang('thread_create');?>"><i class="icon-edit icon"></i></a>
			<?php } ?>
			
			<!--{hook header_nav_user_icon_after.htm}-->
			<div class="navbar-collapse offcanvas-collapse sidebar sidebar-left">
				<!-- 左侧：版块 -->
				<ul class="navbar-nav nav-ul">
					<!--{hook header_nav_forum_start.htm}-->
					<li class="nav-item home" fid="0" data-active="fid-0"><a class="nav-link" href="."><i class="icon-home d-md-none"></i> <?php echo lang('index_page');?></a></li>
					<!--{hook header_nav_home_link_after.htm}-->
					<?php foreach($forumlist_show as $_forum) { ?>
					<!--{hook header_nav_forumlist_loop_start.htm}-->
					<li class="nav-item" fid="<?php echo $_forum['fid'];?>" data-active="fid-<?php echo $_forum['fid'];?>">
						<a class="nav-link" href="<?php echo url("forum-$_forum[fid]");?>"><i class="icon-circle-o d-md-none"></i> <?php echo $_forum['name'];?></a>
					</li>
					<!--{hook header_nav_forumlist_loop_end.htm}-->
					<?php } ?>
					<!--{hook header_nav_forum_end.htm}-->
				</ul>
				<!-- 右侧：搜索 -->
				<ul class="navbar-nav mr-auto d-none d-lg-block" id="scbar">
					<li class="search">
						<form action="<?php echo url('search');?>" id="search_form">
							<div class="input-group">								
								<input type="text" class="form-control" name="keyword" placeholder="关键词">
								<button class="icon icon-search" type="submit" value="<?php echo lang('search');?>"></button>
							</div>
						</form>
					</li>
					<a role="button" class="sifoucn-btn btn-blue submit" href="<?php echo url('thread-create-'.$fid);?>">发帖</a>
				</ul>
				<!-- 右侧：用户 -->
				<ul class="navbar-nav">
					<!--{hook header_nav_user_start.htm}-->
					<?php if(empty($uid)) { ?>
						<li class="nav-item d-none d-lg-block pr-3"><a class="sifoucn-btn btn-blues" href="<?php echo url('user-login');?>"><?php echo lang('login');?></a></li>
						<li class="nav-item d-none d-lg-block pr-0"><a class="sifoucn-btn btn-blue" href="<?php echo url('user-create');?>"><?php echo lang('register');?></a></li>
						<li class="nav-item d-none m-lg-block"><a class="nav-link" href="<?php echo url('user-login');?>"><i class="icon-user"></i> <?php echo lang('login');?></a></li>
					<?php } else { ?>
						<li class="nav-item d-none d-lg-block username dropdown">
							<a href="#" class="nav-link" id="user_dropdown_menu" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"><img class="avatar-3" src="<?php echo $user['avatar_url'];?>" width="35" height="35" /></a>
							<div class="dropdown-menu dropdown-menu-right" aria-labelledby="user_dropdown_menu">
								<!-- 管理员 -->
								<a class="dropdown-item" href="<?php echo url('my');?>"><i class="icon-user"></i> <?php echo $user['username'];?></a>
								<?php if($gid == 1) { ?>
								<a class="dropdown-item" href="admin/" target="_blank"><i class="icon-home"></i> <?php echo lang('admin_page');?></a>
								<?php } ?>
								<a class="dropdown-item" href="<?php echo url('user-logout');?>" target="_blank"><i class="icon-sign-out"></i> <?php echo lang('logout');?></a>
								<!--{hook header_nav_admin_page_after.htm}-->
							</div>
						</li>
						<li class="nav-item hidden-lg username"><a class="nav-link" href="<?php echo url('my');?>"><img class="avatar-1" src="<?php echo $user['avatar_url'];?>"> <?php echo $user['username'];?></a></li>
						<?php if($gid == 1) { ?>
							<li class="nav-item hidden-lg"><a class="nav-link" href="admin/"><i class="icon-home"></i> <?php echo lang('admin_page');?></a></li>
						<?php } ?>
						<!--{hook header_nav_admin_page_after.htm}-->
						<li class="nav-item hidden-lg"><a class="nav-link" href="<?php echo url('user-logout');?>"><i class="icon-sign-out"></i> <?php echo lang('logout');?></a></li>
					<?php } ?>
					<!--{hook header_nav_user_end.htm}-->
				</ul>
			</div>
		</div>
	</header>
	<!--{hook header_nav_end.htm}-->